package com.example.bitcoinconverter;

import java.util.Date;

public class ConverterUtil 
{
	// rate: PLN/Bitcoin
	private static float exchangeRate = 2500;
	
	private static Date date;
	
	public static float convertBitcoinToPLN(float bitcoin) 
	{
		return (bitcoin * exchangeRate);
	}
	
	public static float convertPLNToBitcoin(float pln) 
	{
		return (pln / exchangeRate);
	}
	
	public static float getExchangeRate()
	{
		return exchangeRate;
	}
	
	public static void setExchangeRate(float rate)
	{
		exchangeRate = rate;
	}
	
	public static Date getDate()
	{
		return date;
	}
	
	public static void setDate(Date newDate)
	{
		date = newDate;
	}
}
